#include "GameMain.h"


void GameGridLayer::drawGrid()
{
	/*float rectwidth = GameMain::sharedGameMain()->getBgLayer()->getMapTileWidth();
	float rectheight = GameMain::sharedGameMain()->getBgLayer()->getMapTileHeight();
	float mapsizewidth = GameMain::sharedGameMain()->getBgLayer()->getMapSizeWidth();
	float mapsizeheight = GameMain::sharedGameMain()->getBgLayer()->getMapSizeHeight();

	for(int i = 0 ; i < mapsizewidth;i++)
	{
		for(int j = 0; j < mapsizeheight;j++)
		{
			CCPoint start = CCPointMake(rectwidth * (i + 1),rectheight * (mapsizeheight - j - 1));
			CCSprite *sprite = CCSprite::create();
			sprite->setPosition(start);
			this->addChild(sprite);
			if(GameMain::sharedGameMain()->getBgLayer()->getFlag(i,j))
				sprite->initWithTexture(GameLoader::sharedGameLoader()->getTexture2d("run.pvr.ccz"));
		}
	}
	CHECK_GL_ERROR_DEBUG();*/
}

void GameGridLayer::visble(bool value)
{
	this->setVisible(value);
}